$.ajax({
    url:"getname",
    type:"post",
    success:function (result) {
        var name =result.data;
        $("#name").html(name);
    }
});